<?php

namespace app\controllers;

use app\lib\AppController;
use app\models\RecordModel;
use Yii;
class TestController extends AppController
{
    public function actionTest(){
        $r = new RecordModel();
        $r->questionId = 11;
        $r->uid = 11;
        $r->createTime = 11;
        if(!$r->save()){
            var_dump($r->getErrors());exit;
        }
        return ['hello2','data'=>11];
    }
    public function actionGet(){
        $a = RecordModel::find()->all();
        return [$a];
    }
}
